/*
    Fuck...
    这件事告诉我们，我一定要按照我自己的习惯来......
    我就是习惯了 s放在元素前面
*/

#include "stack.h"

#include <stdlib.h>
#include <stdio.h>

void test_stack(void)
{
    Stack s;

    s = CreateStack();
    if(NULL == s)
    {
        printf("Create Stack failed !!!\n");
        return;
    }

    PushStack(5,s);

    PushStack(3,s);
    PushStack(8,s);

    printf("Now Stack Top:%d\n",TopStack(s));

    PushStack(1,s);
    printf("Now Stack Top:%d\n",TopStack(s));

    PopStack(s);
    printf("Now Stack Top:%d\n",TopStack(s));

    PopStack(s);
    printf("Now Stack Top:%d\n",TopStack(s));   

    PushStack(7,s);
    printf("Now Stack Top:%d\n",TopStack(s));  

    DisposeStack(s);   
}


// end of file ----------------------------------------------------------------
